from hocabul.models import School, Course, Department, UserProfile, EventType, Location, Lesson, LessonsContributors
import fileinput
import re
from collections import defaultdict
from django.db import connection
from django.db import settings
from datetime import datetime
import datetime

##Create school
#school = School(name="koc university")
#school.save()
#
## Create event types
#et1 = EventType.objects.create(abbr='lesson', label='Class lesson')
#et2 = EventType.objects.create(abbr='busy', label='Busy Time')

user = UserProfile.objects.filter(first_name='jack')[0]
lesson = Lesson.objects.filter(id=1)[0]
LessonsContributors.objects.create(user=user,lesson=lesson, is_teacher=False)
